#29 ✓resolved
Rick DeNatale

Supress X-RICAL-TZSOURCE= when not relevant

Reported by Rick DeNatale | April 16th, 2010 @ 05:57 PM

---------- Forwarded message ---------- From: Alejandro Gonzalez <mrgonza78@gmail.com>
Date: Fri, Apr 16, 2010 at 5:15 PM
Subject: [RiCal] Can't parse ical twice
To: rical_gem@googlegroups.com

Hello,
  I'm having a problem that can be reproduced with the following
snippet of code...
ical_string = %Q(BEGIN:VCALENDAR
PRODID:-//Google Inc//Google Calendar 70.9054//EN
BEGIN:VEVENT
DTSTART:20100610T100000
DTEND:20100610T110000
END:VEVENT
END:VCALENDAR)
RiCal.parse_string(RiCal.parse_string(ical_string).to_s)
  ... and the output is ...
RuntimeError: Invalid parameter value "X-RICAL-TZSOURCE="
from /home/mrgonza78/grid/pokety-poke/vendor/gems/ri_cal-0.8.5/lib/ri_cal/parser.rb:27:in
parse_params'         ...

It's not that I like to parse things twice :P .....in my real use case
I'm parsing an ical received by email, inspecting it, storing it in a
db (using calendar#to_s) and then I'm having the above problem the
second time I try to parse the stored ical.
in the snippet, I removed lot of info from the sample ical just for
the sake of clarity, but I'm having the same problem with the original
ical (generated by google calendar) which is attached just in case.
One thing I noticed is that if a remove the PRODID line from the ical
string, eveything works fine...
so... does someone know if ....this a bug? I'm doing something wrong?
or the google ical doesn't respect some standard?
Thanks in advance
Alejandro

-- You received this message because you are subscribed to the Google
Groups "RiCal" group.
To post to this group, send email to rical_gem@googlegroups.com.
To unsubscribe from this group, send email to
rical_gem+unsubscribe@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/rical_gem?hl=en.

-- Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Github: http://github.com/rubyredrick
Twitter: @RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

A new icalendar data (RFC 2445) gem for Ruby which supports time zones and enumeration of occurrences

Shared Ticket Bins

People watching this ticket

Pages